using System;
using System.Collections.Generic;
using System.Text;

namespace MspEmulator
{
    class makeMeasuring : ISend, IMakeMeasuring
    {
        private ushort eTime;

        private ushort mTime;

        public makeMeasuring(ushort value1, ushort value2)
        {
            eTime = value1;
            mTime = value2;
        }

        #region ISend Members

        public void Send()
        {
            Serial.Send(Utility.buildPack(Utility.collectData((byte)Utility.functCode.Measure)));
        }

        #endregion

        #region IMakeMeasuring Members

        public void Make()
        {
            Commander.Measure(eTime, mTime);
        }

        #endregion
    }
}
